<?php 

$calender=$jCalender->getCalArr($timestamp);

$nextmonth=strtotime("+1 month",$timestamp);
$prevmonth=strtotime("-1 month",$timestamp);


$weekDays=array('Sunday'=>'রবি','Monday'=>'শনি','Tuesday'=>'মঙ্গল','Wednesday'=>'বুধ','Thursday'=>'বৃহ','Friday'=>'শুক্র','Saturday'=>'শনি');

 ?>
                    <div class="clenderTop">
                        <select class="select month" id="calender_month"
                            onchange="jcalender(document.getElementById('calender_year').value,document.getElementById('calender_month').value); return false;"
                            >
                            <option value="01" <?php if($month==01) echo 'selected="selected"' ?>>জানুয়ারি</option>
                            <option value="02" <?php if($month==02) echo 'selected="selected"' ?>>ফেব্রুয়ারি</option>
                            <option value="03" <?php if($month==03) echo 'selected="selected"' ?>>মার্চ</option>
                            <option value="04" <?php if($month==04) echo 'selected="selected"' ?>>এপ্রিল</option>
                            <option value="05" <?php if($month==05) echo 'selected="selected"' ?>>মে</option>
                            <option value="06" <?php if($month==06) echo 'selected="selected"' ?>>জুন</option>
                            <option value="07" <?php if($month==07) echo 'selected="selected"' ?>>জুলাই</option>
                            <option value="08" <?php if($month==08) echo 'selected="selected"' ?>>আগস্ট</option>
                            <option value="09" <?php if($month==09) echo 'selected="selected"' ?>>সেপ্টেম্বর</option>
                            <option value="10" <?php if($month==10) echo 'selected="selected"' ?>>অক্টোবর</option>
                            <option value="11" <?php if($month==11) echo 'selected="selected"' ?>>নভেম্বর</option>
                            <option value="12" <?php if($month==12) echo 'selected="selected"' ?>>ডিসেম্বর</option>
                        </select>
                        <select class="select year" id="calender_year" 
                            onchange="jcalender(document.getElementById('calender_year').value,document.getElementById('calender_month').value); return false;"
                            >
                            <?php for($i=$year-5;$i<$year+5;$i++): ?>
                            <option value="<?php echo $i ?>" <?php if($i==$year) echo 'selected="selected"' ?>><?php echo $common->toBnNum($i) ?></option>
                            <?php endfor ?>
                        </select>
                    </div>
                    <dl class="dayZone">
                        <?php foreach($calender[0] as $day=>$val): ?>
                        <dt><?php echo $weekDays[$day] ?></dt>
                        <?php endforeach ?>
                    </dl>
                    
                    <dl class="dateZone">
                        <?php foreach($calender as $week): ?>
                            <?php foreach($week as $day=>$val): ?>
                                <?php if(isset($publish[date("Y-m-d",$val)])): ?>
                                <dd <?php if(date('Y-m',$val)!=date('Y-m',$timestamp)) echo 'class="gray"' ?>>
                                    <a href="<?php echo $html->url('/news/archive/'.$publish[date("Y-m-d",$val)]) ?>"><?php echo $common->toBnNum(date('d',$val)) ?></a>
                                </dd>
                                <?php else: ?>
                                <dd class="disabled <?php if(date('Y-m',$val)!=date('Y-m',$timestamp)) echo 'gray' ?>">
                                    <?php echo $common->toBnNum(date('d',$val)) ?>
                                </dd>
                                <?php endif; ?>
                            <?php endforeach ?>
                        <?php endforeach ?>
                    </dl>
                    <div class="calenderFooter">
                        <a class="previous fL"  href="#" onclick="jcalender('<?php echo date('Y',$prevmonth)  ?>','<?php echo date('m',$prevmonth) ?>'); return false;">&lt; পূর্বের মাস</a>
                        <a class="next fR"  href="#" onclick="jcalender('<?php echo date('Y',$nextmonth)  ?>','<?php echo date('m',$nextmonth) ?>'); return false;">পরবর্তী মাস &gt;</a>
                    </div>